unit uAboutBox;

interface

uses Windows, SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,
  Buttons, ExtCtrls ,ShellAPI, dxGDIPlusClasses;

type
  TAboutBox = class(TForm)
    Panel1: TPanel;
    ProgramIcon: TImage;
    ProductName: TLabel;
    Version: TLabel;
    Copyright: TLabel;
    Comments: TLabel;
    OKButton: TButton;
    procedure FormCreate(Sender: TObject);
    procedure FormClose(Sender: TObject; var Action: TCloseAction);
    procedure CopyrightClick(Sender: TObject);
    procedure CopyrightMouseEnter(Sender: TObject);
    procedure CopyrightMouseLeave(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  AboutBox: TAboutBox;

implementation
uses Net;
{$R *.dfm}

procedure TAboutBox.CopyrightClick(Sender: TObject);
begin
  ShellExecute(Handle,'open',PAnsiChar(Copyright.Hint),nil,nil,SW_SHOWNORMAL);
end;

procedure TAboutBox.CopyrightMouseEnter(Sender: TObject);
begin
  Copyright.Font.Color := clBlue;
  Copyright.Font.Style := Copyright.Font.Style+[fsUnderline];
end;

procedure TAboutBox.CopyrightMouseLeave(Sender: TObject);
begin
  Copyright.Font.Color := clBlack;
  Copyright.Font.Style := Copyright.Font.Style-[fsUnderline];
end;

procedure TAboutBox.FormClose(Sender: TObject; var Action: TCloseAction);
begin
  Action := caFree;
end;

procedure TAboutBox.FormCreate(Sender: TObject);
begin
  ProductName.Caption := ProductName.Caption+' Ver '+Get_Version;
  Version.Caption := 'Ver '+Get_Version;
end;

end.
 
